package com.punch.order.model;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.punch.common.model.SuperEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;

/**
 * <p>
 * 订单详情
 * </p>
 *
 * @author wjj
 * @since 2020-12-09
 */
@Data
@EqualsAndHashCode(callSuper = true)
@Accessors(chain = true)
@TableName("common_order_detail")
public class CommonOrderDetail extends SuperEntity<CommonOrderDetail> {

    private static final long serialVersionUID = 1L;

    /**
     * 订单id
     */
    @TableField("order_id")
    private Long orderId;

    /**
     * 订单编号
     */
    @TableField("order_sn")
    private String orderSN;

    /**
     * 产品类型 0-课程 1-教具/教材商品
     */
    @TableField("product_type")
    private Boolean productType;

    /**
     * 产品id
     */
    @TableField("product_id")
    private Long productId;

    /**
     * 产品名称
     */
    @TableField("product_name")
    private String productName;

    /**
     * 单价
     */
    @TableField("price")
    private Integer price;

    /**
     * 原价
     */
    @TableField("original_price")
    private Integer originalPrice;

    /**
     * 数量
     */
    @TableField("quantity")
    private Integer quantity;

    /**
     * 小计金额
     */
    @TableField("total_amount")
    private Integer totalAmount;

    /**
     * 订单用户uid
     */
    @TableField("create_id")
    private Long createId;


    @Override
    protected Serializable pkVal() {
        return null;
    }

}
